﻿<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="OrdersRecently.ascx.cs"
    Inherits="TCKQKL.FrontEnd.Web.Controls.OrderAlert" %>
<link href="../styles/data.css" rel="stylesheet" type="text/css" />
<%@ Import Namespace="TCKQKL.FrontEnd.DataModel" %>
<%@ Import Namespace="TCKQKL.FrontEnd.Config" %>
<table class="data" style="border: none;">
    <% if (orderData != null)
           if (orderData.Count > 0)
           {%>
    <tr>
        <td class="OrderAlertMessageStyle" colspan="9">
            <img alt="Orders" src="./Images/orders.jpg" style="width: 30px; height: 24px" />Lệnh
            đặt gần đây
        </td>
        <%--<td colspan="6" 
            style="text-align: right; vertical-align: bottom; font-size: 11px;">
            No of line:<asp:DropDownList ID="numberOfOrder" runat="server">
                <asp:ListItem Selected="True">5</asp:ListItem>
                <asp:ListItem>10</asp:ListItem>
                <asp:ListItem>15</asp:ListItem>
                <asp:ListItem>20</asp:ListItem>
            </asp:DropDownList>
            From:
            <input type="text" name="orderFrom" maxlength="10" />
            To:
            <input type="text" name="orderTo" maxlength="10" />
        </td>--%>
    </tr>
    <tr>
        <th class="InnerHeading">
            Order ID
        </th>
        <th class="InnerHeading">
            Date
        </th>
        <th class="InnerHeading">
            Type
        </th>
        <th class="InnerHeading">
            Class
        </th>
        <th class="InnerHeading">
            Side
        </th>
        <th class="InnerHeading">
            Symbol
        </th>
        <th class="InnerHeading">
            Quantity
        </th>
        <th class="InnerHeading">
            Price
        </th>
        <th class="InnerHeading">
            Value
        </th>
    </tr>
    <%for (int i = 0; i < orderData.Count; i++)
      { %>
    <tr>
        <td class="InnerData">
            <%=orderData[i].orderID%>
        </td>
        <td class="InnerData">
            <%=orderData[i].openDate.ToString("dd/MM/yyyy") %>
        </td>
        <td class="InnerData">
            <%=orderData[i].orderType%>
        </td>
        <td class="InnerData">
            <%=orderData[i].OrderClass%>
        </td>
        <td class="Master">
            <%=orderData[i].OrderSide%>
        </td>
        <td class="Master">
            <%=orderData[i].symbol%>
        </td>
        <td class="Master" style="text-align: right">
            <%=String.Format("{0:0,0}", orderData[i].quantity)%>
        </td>
        <td class="Master" style="text-align: right">
            <%=String.Format("{0:0,0}", orderData[i].price)%>
        </td>
        <td class="Master" style="text-align: right">
            <%=String.Format("{0:0,0}", orderData[i].quantity * orderData[i].price)%>
        </td>
    </tr>
    <%}%>
    <%}%>
</table>
